package homework;

import lombok.*;

import java.util.Objects;

/**
 * @classname:SE
 * @description:
 * @author: Mr.Z
 * @date: 2020/12/11 17:53
 * @version: 0.1
 * @since:1.8
 */
@Setter
@Getter
@NoArgsConstructor
@AllArgsConstructor
@ToString
public class SE extends Employee {
    private String name;
    private Integer age;
    private Integer salary;


    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        SE se = (SE) o;
        return Objects.equals(name, se.name) &&
                Objects.equals(age, se.age) &&
                Objects.equals(salary, se.salary);
    }

    @Override
    public int hashCode() {
        return Objects.hash(name, age, salary);
    }

    @Override
    public void showInfo() {
        System.out.println("程序员的名字" + name + "年龄" + age + "薪资" + salary);
    }
}
